home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Toolbox / Visual Basic Toolbox (P.I.E.)(1996).ISO / gauge / agavb20 / gframes.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1995-06-25  |  11.5 KB  |  373 lines

  1. VERSION 2.00
  2. Begin Form FrameDemo 
  3.    BackColor       =   &H00C0C0C0&
  4.    BorderStyle     =   1  'Fixed Single
  5.    Caption         =   "Frame & Background Demo"
  6.    ClientHeight    =   4410
  7.    ClientLeft      =   1020
  8.    ClientTop       =   1455
  9.    ClientWidth     =   6435
  10.    Height          =   4815
  11.    Left            =   960
  12.    LinkTopic       =   "Form2"
  13.    MaxButton       =   0   'False
  14.    MDIChild        =   -1  'True
  15.    MinButton       =   0   'False
  16.    ScaleHeight     =   4410
  17.    ScaleWidth      =   6435
  18.    Top             =   1110
  19.    Width           =   6555
  20.    Begin AGAUGE Gauge1 
  21.       Angle           =   0
  22.       BackgroundColor =   &H00C0C0C0&
  23.       BevelInner      =   0  ' 0 - None
  24.       BevelOuter      =   0  ' 0 - None
  25.       BevelWidth      =   2
  26.       BorderType      =   1  ' 1 - Bevel
  27.       BorderWidth     =   0
  28.       FrameColor      =   &H00000000&
  29.       FrameScaleX     =   1.1
  30.       FrameScaleY     =   1.1
  31.       FrameStyle      =   1  ' 1 - Circle
  32.       Height          =   3015
  33.       Left            =   120
  34.       MouseControl    =   -1  'True
  35.       OutlineAlign    =   0  ' 0 - Left 
  36.       OutlineColor    =   &H00000000&
  37.       OutlineTitle    =   ""
  38.       OutlineWidth    =   0
  39.       Radius          =   0
  40.       Scales          =   GFRAMES.FRX:0000
  41.       Shape           =   ""
  42.       TabIndex        =   2
  43.       Top             =   1230
  44.       Value           =   0
  45.       Width           =   3225
  46.       XScale          =   0
  47.       YScale          =   0
  48.    End
  49.    Begin Frame Frame1 
  50.       BackColor       =   &H00C0C0C0&
  51.       Caption         =   "Picture Properties"
  52.       Height          =   1695
  53.       Left            =   3570
  54.       TabIndex        =   18
  55.       Top             =   1170
  56.       Width           =   2625
  57.       Begin OptionButton Option1 
  58.          BackColor       =   &H00C0C0C0&
  59.          Caption         =   "FramePicture"
  60.          Height          =   225
  61.          Index           =   0
  62.          Left            =   300
  63.          TabIndex        =   7
  64.          Top             =   300
  65.          Value           =   -1  'True
  66.          Width           =   2235
  67.       End
  68.       Begin OptionButton Option1 
  69.          BackColor       =   &H00C0C0C0&
  70.          Caption         =   "BackgroundPicture"
  71.          Height          =   225
  72.          Index           =   1
  73.          Left            =   300
  74.          TabIndex        =   8
  75.          Top             =   540
  76.          Width           =   2235
  77.       End
  78.       Begin PictureBox Image1 
  79.          Height          =   645
  80.          Index           =   4
  81.          Left            =   1620
  82.          Picture         =   GFRAMES.FRX:006C
  83.          ScaleHeight     =   41
  84.          ScaleMode       =   3  'Pixel
  85.          ScaleWidth      =   41
  86.          TabIndex        =   9
  87.          Top             =   930
  88.          Width           =   645
  89.       End
  90.       Begin PictureBox Image1 
  91.          Height          =   645
  92.          Index           =   2
  93.          Left            =   960
  94.          Picture         =   GFRAMES.FRX:46A6
  95.          ScaleHeight     =   41
  96.          ScaleMode       =   3  'Pixel
  97.          ScaleWidth      =   41
  98.          TabIndex        =   10
  99.          Top             =   930
  100.          Width           =   645
  101.       End
  102.       Begin PictureBox Image1 
  103.          Height          =   645
  104.          Index           =   0
  105.          Left            =   300
  106.          Picture         =   GFRAMES.FRX:8C80
  107.          ScaleHeight     =   41
  108.          ScaleMode       =   3  'Pixel
  109.          ScaleWidth      =   41
  110.          TabIndex        =   11
  111.          Top             =   930
  112.          Width           =   645
  113.       End
  114.    End
  115.    Begin Frame Frame4 
  116.       BackColor       =   &H00C0C0C0&
  117.       Caption         =   "Color Properties"
  118.       Height          =   1395
  119.       Left            =   3570
  120.       TabIndex        =   23
  121.       Top             =   2850
  122.       Width           =   2625
  123.       Begin OptionButton Option3 
  124.          BackColor       =   &H00C0C0C0&
  125.          Caption         =   "BackgroundColor"
  126.          Height          =   195
  127.          Index           =   1
  128.          Left            =   330
  129.          TabIndex        =   12
  130.          Top             =   540
  131.          Width           =   2115
  132.       End
  133.       Begin OptionButton Option3 
  134.          BackColor       =   &H00C0C0C0&
  135.          Caption         =   "FrameColor"
  136.          Height          =   195
  137.          Index           =   0
  138.          Left            =   330
  139.          TabIndex        =   13
  140.          Top             =   300
  141.          Value           =   -1  'True
  142.          Width           =   2115
  143.       End
  144.       Begin Label HColors 
  145.          BackColor       =   &H000080FF&
  146.          Height          =   225
  147.          Index           =   4
  148.          Left            =   1230
  149.          TabIndex        =   14
  150.          Top             =   990
  151.          Width           =   225
  152.       End
  153.       Begin Label HColors 
  154.          BackColor       =   &H00000000&
  155.          Height          =   225
  156.          Index           =   0
  157.          Left            =   270
  158.          TabIndex        =   19
  159.          Top             =   990
  160.          Width           =   225
  161.       End
  162.       Begin Label HColors 
  163.          BackColor       =   &H00808080&
  164.          Height          =   225
  165.          Index           =   5
  166.          Left            =   1470
  167.          TabIndex        =   20
  168.          Top             =   990
  169.          Width           =   225
  170.       End
  171.       Begin Label HColors 
  172.          BackColor       =   &H00FFFFFF&
  173.          Height          =   225
  174.          Index           =   1
  175.          Left            =   510
  176.          TabIndex        =   21
  177.          Top             =   990
  178.          Width           =   225
  179.       End
  180.       Begin Label HColors 
  181.          BackColor       =   &H000000FF&
  182.          Height          =   225
  183.          Index           =   6
  184.          Left            =   1710
  185.          TabIndex        =   22
  186.          Top             =   990
  187.          Width           =   225
  188.       End
  189.       Begin Label HColors 
  190.          BackColor       =   &H0000FF00&
  191.          Height          =   225
  192.          Index           =   2
  193.          Left            =   750
  194.          TabIndex        =   27
  195.          Top             =   990
  196.          Width           =   225
  197.       End
  198.       Begin Label HColors 
  199.          BackColor       =   &H0000FFFF&
  200.          Height          =   225
  201.          Index           =   7
  202.          Left            =   1950
  203.          TabIndex        =   26
  204.          Top             =   990
  205.          Width           =   225
  206.       End
  207.       Begin Label HColors 
  208.          BackColor       =   &H00FF0000&
  209.          Height          =   225
  210.          Index           =   3
  211.          Left            =   990
  212.          TabIndex        =   25
  213.          Top             =   990
  214.          Width           =   225
  215.       End
  216.       Begin Label HColors 
  217.          BackColor       =   &H00FF00FF&
  218.          Height          =   225
  219.          Index           =   8
  220.          Left            =   2190
  221.          TabIndex        =   24
  222.          Top             =   990
  223.          Width           =   225
  224.       End
  225.    End
  226.    Begin Frame Frame2 
  227.       BackColor       =   &H00C0C0C0&
  228.       Caption         =   "FrameStyle"
  229.       Height          =   1095
  230.       Left            =   390
  231.       TabIndex        =   15
  232.       Top             =   60
  233.       Width           =   1575
  234.       Begin OptionButton Option2 
  235.          BackColor       =   &H00C0C0C0&
  236.          Caption         =   "Rectangle"
  237.          Height          =   225
  238.          Index           =   2
  239.          Left            =   210
  240.          TabIndex        =   6
  241.          Top             =   750
  242.          Width           =   1245
  243.       End
  244.       Begin OptionButton Option2 
  245.          BackColor       =   &H00C0C0C0&
  246.          Caption         =   "Circle"
  247.          Height          =   225
  248.          Index           =   1
  249.          Left            =   210
  250.          TabIndex        =   17
  251.          Top             =   510
  252.          Width           =   1095
  253.       End
  254.       Begin OptionButton Option2 
  255.          BackColor       =   &H00C0C0C0&
  256.          Caption         =   "None"
  257.          Height          =   225
  258.          Index           =   0
  259.          Left            =   210
  260.          TabIndex        =   16
  261.          Top             =   270
  262.          Width           =   1125
  263.       End
  264.    End
  265.    Begin HScrollBar HScroll1 
  266.       Height          =   225
  267.       Index           =   1
  268.       Left            =   2310
  269.       Max             =   140
  270.       TabIndex        =   3
  271.       Top             =   840
  272.       Width           =   3885
  273.    End
  274.    Begin HScrollBar HScroll1 
  275.       Height          =   225
  276.       Index           =   0
  277.       Left            =   2310
  278.       Max             =   140
  279.       TabIndex        =   0
  280.       Top             =   420
  281.       Width           =   3885
  282.    End
  283.    Begin Label Label2 
  284.       Alignment       =   2  'Center
  285.       AutoSize        =   -1  'True
  286.       BackStyle       =   0  'Transparent
  287.       Caption         =   " "
  288.       Height          =   195
  289.       Index           =   1
  290.       Left            =   4185
  291.       TabIndex        =   4
  292.       Top             =   630
  293.       Width           =   120
  294.    End
  295.    Begin Label Label1 
  296.       AutoSize        =   -1  'True
  297.       BackStyle       =   0  'Transparent
  298.       Caption         =   "Frame Scale Y:"
  299.       Height          =   195
  300.       Index           =   1
  301.       Left            =   2310
  302.       TabIndex        =   5
  303.       Top             =   660
  304.       Width           =   1305
  305.    End
  306.    Begin Label Label1 
  307.       AutoSize        =   -1  'True
  308.       BackStyle       =   0  'Transparent
  309.       Caption         =   "Frame Scale X:"
  310.       Height          =   195
  311.       Index           =   0
  312.       Left            =   2310
  313.       TabIndex        =   1
  314.       Top             =   240
  315.       Width           =   1305
  316.    End
  317.    Begin Label Label2 
  318.       Alignment       =   2  'Center
  319.       AutoSize        =   -1  'True
  320.       BackStyle       =   0  'Transparent
  321.       Caption         =   " "
  322.       Height          =   195
  323.       Index           =   0
  324.       Left            =   4185
  325.       TabIndex        =   28
  326.       Top             =   210
  327.       Width           =   150
  328.    End
  329. Sub Form_Load ()
  330.     hscroll1(0) = gauge1.FrameScaleX * 100
  331.     hscroll1(1) = gauge1.FrameScaleY * 100
  332.     option2(gauge1.FrameStyle) = True
  333. End Sub
  334. Sub HColors_Click (index As Integer)
  335.     If option3(0) Then
  336.         gauge1.FrameColor = hcolors(index).BackColor
  337.         gauge1.FramePicture = LoadPicture("")
  338.     Else
  339.         gauge1.BackgroundColor = hcolors(index).BackColor
  340.         gauge1.BackgroundPicture = LoadPicture("")
  341.     End If
  342. End Sub
  343. Sub HScroll1_Change (index As Integer)
  344.     Select Case index
  345.         Case 0
  346.             gauge1.FrameScaleX = hscroll1(0) / 100
  347.             label2(0) = hscroll1(0) / 100
  348.         Case 1
  349.             gauge1.FrameScaleY = hscroll1(1) / 100
  350.             label2(1) = hscroll1(1) / 100
  351.     End Select
  352. End Sub
  353. Sub HScroll1_Scroll (index As Integer)
  354.     Select Case index
  355.         Case 0
  356.             gauge1.FrameScaleX = hscroll1(0) / 100
  357.             label2(0) = hscroll1(0) / 100
  358.         Case 1
  359.             gauge1.FrameScaleY = hscroll1(1) / 100
  360.             label2(1) = hscroll1(1) / 100
  361.     End Select
  362. End Sub
  363. Sub Image1_Click (index As Integer)
  364.     If option1(0) Then
  365.         gauge1.FramePicture = Image1(index).Picture
  366.     Else
  367.         gauge1.BackgroundPicture = Image1(index).Picture
  368.     End If
  369. End Sub
  370. Sub Option2_Click (index As Integer)
  371.     gauge1.FrameStyle = index
  372. End Sub
  373.